package com.cy.pj.goods.pojo;
import com.fasterxml.jackson.annotation.JsonFormat;
import lombok.AllArgsConstructor;
import lombok.Data;
import lombok.NoArgsConstructor;

import java.util.Date;

/**pojo：用于封装商品信息*/
//@Setter
//@Getter
//@ToString

@Data
@NoArgsConstructor
@AllArgsConstructor
public class Goods {//Goods.java-->javac-->Goods.class

    private Long id;
    private String name;
    private String remark;
    //告诉spring web模块将对象转换为json串时，这个日期按照指定格式进行转换
    @JsonFormat(pattern="yyyy/MM/dd HH:mm:ss")
    private Date createdTime;
}
